import { defineStore  } from 'pinia'
import { getHospitalDetailAPI} from '@/api/hospital'
const useDetailStore = defineStore('detail', {
    state: () => {
        return {
            // 医院详情信息
            hospitalInfo: {}
        }
    },
    actions: {
        // 获取医院详情
       async getHospitalDetail(hoscode) {
        const res  = await  getHospitalDetailAPI(hoscode)
        // console.log(res);
        this.hospitalInfo = res.data

        }
    },
    getters: {

    }

})

export default useDetailStore